package com.heima.article.controller.v1;

import com.heima.article.service.ApArticleService;
import com.heima.model.common.dtos.ResponseResult;
import com.heima.model.wemedia.dtos.NewsAuthDto;
import com.heima.model.wemedia.pojos.WmNews;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RequiredArgsConstructor
@RestController
@RequestMapping
public class SaveNews {

    private final ApArticleService articleService;



    @PostMapping("/news/author")
    public ResponseResult saveToApp(@RequestBody NewsAuthDto authDto){
        return articleService.saveToApp(authDto);
    }

}
